package com.ikun.service;

import com.ikun.pojo.DeliveryAddress;
import com.ikun.pojo.User;

import java.util.List;

public interface UserService {
    //根据username与password查找用户
    public User getUserByUsernameAndPassword(String username, String password);
    //添加用户
    public int addUser(String username, String password);
    //根据用户查询其收货地址
    public List<DeliveryAddress> getAddressesByUserId(Integer userId);
    //添加收货地址
    public int addAddress(DeliveryAddress deliveryAddress);
    //根据收货地址的id修改收货地址
    public int updateAddressByAddressId(DeliveryAddress deliveryAddress);
    //根据收货地址的id删除收货地址
    public int deleteAddressByAddressId(Integer addressId);
    public User getUserById(Integer id);
    public void updateNameByUserId(Integer userId, String briefIntroduction);
    void updateBriefIntroductionByUserId(Integer userId, String briefIntroduction);

    void updateUserNameByUserId(Integer userId, String userName);
    public void updateAvatar(Integer userId,String resultUrl);

}
